package com.house365.arequest.error;

public enum ErrorType {
    UNKNOW(0, "未知错误"),
    NETWORK(1, "网络请求失败，请检查您的网络设置"),
    IOERROR(2, "网络请求失败"),
    UNKNOW_HOST(3, "服务连接超时"),
    TIME_OUT(4, "服务连接超时"),
    HTTP(5, "获取数据失败"),
    JSON(6, "数据解析失败"),
    REQUEST_FAIL(7, "请求失败，请稍后重试");

    int code;
    String msg;

    ErrorType(int code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public String getMsg() {
        return msg;
    }
}
